﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace DtsExplorerProject.Helpers
{
    static public class StringHelperClass
    {
        static public bool MultiContains(this string s,params string[] keys) 
        {
            bool result = false;
            foreach (string item in keys)
            {
                bool local = s.Contains(item);
                result |= local;
            }

            return result;
        }

        static public string SubstringExtension(this string s,int startIndex,int endIndex)
        {
            char[] charcollection = s.ToCharArray();
            StringBuilder result = new StringBuilder();
            for (int i = startIndex; i < endIndex; i++)
            {
                result.Append(charcollection[i]);
            }
            return result.ToString();
        }

    }
}
